#include <bits/stdc++.h>

using namespace std;

typedef long long ll;
typedef double db;

#define in read()
#define pii pair<int,int>
#define fi first
#define se second
#define FILE(x) freopen(x".in","r",stdin);\
	freopen(x".out","w",stdout);
#define pb push_back

int read(){
	int x = 0,sgn = 1;char ch = getchar();
	for(;!isdigit(ch);ch = getchar()) if(ch == '-') sgn = -1;
	for(;isdigit(ch);ch = getchar()) x = (x<<1)+(x<<3)+(ch^48);
	return x*sgn;
}

const int N = 1e5+10;
const int mod = 998244353;

int rev[N<<2],n;
ll F[N<<2],G[N<<2],A[N<<2],B[N<<2],a[N<<2],b[N<<2],Wn[N<<2];

ll qp(ll x,int t){ll res=1;for(;t;t>>=1,x=x*x%mod)if(t&1)res=res*x%mod;return res;}

void NTT(ll *f,int len,int on = 1){
	for(int i = 1;i < len;i++) if(i < rev[i]) swap(f[i],f[rev[i]]);
	for(int h = 2;h <= len;h <<= 1){
		ll wn = Wn[h];
		for(int i = 0;i < len;i += h){
			ll ww = 1;
			for(int k = i;k < i + h/2;k++){
				ll u = f[k],v = f[k+h/2] * ww % mod; ww = wn * ww % mod;
				f[k] = (u + v) % mod,f[k+h/2] = (u - v + mod) % mod;
			}
		}
	}if(on == -1){reverse(f+1,f+len);ll invv = qp(len,mod-2);for(int i = 0;i < len;i++) f[i] = f[i] * invv % mod;}
}

void getinv(int deg,ll *f,ll *g){
	if(deg == 1) return g[0] = qp(f[0],mod-2),void();
	getinv(deg+1>>1,f,g); int len = 1;for(;len<2*deg;len<<=1);
	for(int i = 0;i < deg;i++) a[i] = f[i]; for(int i = deg;i < len;i++) a[i] = 0;
	for(int i = 0;i < len;i++) rev[i] = rev[i>>1] >> 1 | (i & 1 ? len >> 1 : 0);
	NTT(a,len); NTT(g,len); for(int i = 0;i < len;i++) g[i] = g[i] * (2ll + mod - g[i] * a[i] % mod) % mod;
	NTT(g,len,-1); for(int i = deg;i < len;i++) g[i] = 0;
}

void Dao(int len,ll *f,ll *g){for(int i = 1;i < len;i++) g[i-1] = f[i] * i % mod;g[len] = 0;}

void Jifen(int len,ll *f,ll *g){for(int i = 1;i < len;i++) g[i] = f[i-1] * qp(i,mod-2) % mod;g[0] = 0;}

void Getln(int deg,ll *f,ll *g){
	Dao(deg,f,A); getinv(deg,f,B);
	int len = 1;for(;len < 2 * deg;len<<=1); for(int i = 1;i < len;i++) rev[i] = rev[i>>1]>>1 | (i & 1 ? len>>1:0);
	NTT(A,len); NTT(B,len); for(int i = 0;i < len;i++) A[i] = A[i] * B[i] % mod;
	NTT(A,len,-1); Jifen(len,A,g);
}

int main (){
#ifndef ONLINE_JUDGE
	freopen("1.in","r",stdin);
#endif
	for(int h = 1;h < N<<2;h<<=1) Wn[h] = qp(3,(mod-1)/h);
	n = in; for(int i = 0;i < n;i++) F[i] = in;
	Getln(n,F,G); for(int i = 0;i < n;i++) printf("%d ",G[i]);
	return 0;
}

